﻿<%@ Page Language="C#" MasterPageFile="~/home.master" AutoEventWireup="true" CodeFile="signin.aspx.cs" Inherits="signin" Title="Sign In" ValidateRequest="false" %>
<%@ Register assembly="BasicFrame.WebControls.BasicDatePicker" namespace="BasicFrame.WebControls" tagprefix="BDP" %>
<%@ Register assembly="FreeTextBox" namespace="FreeTextBoxControls" tagprefix="FTB" %>
<asp:Content ContentPlaceHolderID="head" Runat="Server">
<fieldset>
    <legend>
        <div style="font-size:25px;color:#F00">Sign In</div>    
    </legend>
    <div id="layout_register" runat="server">
        <asp:ValidationSummary runat="server" ValidationGroup="vl" />
        <table id="layout_infor" width="100%" runat="server" border="0" cellspacing="5" style="font-size: 18px">
            <tr>
                <td width="200" align="right">Email</td>
                <td>
                    <asp:TextBox ID="txt_email" class="input_text_view" runat="server"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txt_email"
                        ErrorMessage="Email is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txt_email"
                        ErrorMessage="Email invalid." ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
                        ValidationGroup="vl">*</asp:RegularExpressionValidator>                                
                </td>
            </tr>
            <tr>
                <td align="right">Password</td>
                <td>
                    <asp:TextBox ID="txt_password" class="input_text_view" TextMode="Password" runat="server"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txt_password"
                        ErrorMessage="Password is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td align="right">Confirm Password</td>
                <td>
                    <asp:TextBox ID="txt_cpassword" class="input_text_view" TextMode="Password" runat="server"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txt_cpassword"
                        ErrorMessage="Confirm password is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                    <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="txt_password"
                        ControlToValidate="txt_cpassword" ErrorMessage="Confirm password invalid." ValidationGroup="vl">*</asp:CompareValidator>
                </td>
            </tr>
            <tr>
                <td align="right">Name</td>
                <td>
                    <asp:TextBox ID="txt_name" class="input_text_view" runat="server"></asp:TextBox>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="txt_name"
                        ErrorMessage="Name is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>                           
                </td>
            </tr>
            <tr>
                <td align="right">Address</td>
                <td>
                    <asp:TextBox ID="txt_address" class="input_text_view" runat="server" ></asp:TextBox>
                     <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="txt_address"
                        ErrorMessage="Address is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td align="right">City</td>
                <td>
                    <asp:TextBox ID="txt_city" class="input_text_view" runat="server" ></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="txt_city"
                        ErrorMessage="City is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>   
                </td>
            </tr>

             <tr>
                <td align="right">Country</td>
                <td>
                    <asp:TextBox ID="txt_country" class="input_text_view" runat="server" ></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" ControlToValidate="txt_country"
                        ErrorMessage="Country is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td align="right">Phone</td>
                <td>
                    <asp:TextBox ID="txt_phone" class="input_text_view" runat="server"></asp:TextBox>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ControlToValidate="txt_phone"
                        ErrorMessage="Phone enter only numbers" ValidationExpression="^\d+$" ValidationGroup="vl">*</asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td align="right" valign="top">Description</td>
                <td>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="ftb_description"
                        ErrorMessage="Description is not empty." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                    <FTB:FreeTextBox ID="ftb_description" Height="200px" Width="100%" 
                        runat="server" ButtonSet="OfficeMac">
                    </FTB:FreeTextBox>
                </td>
            </tr>
            <tr>
                <td align="right">Birthday</td>
                <td>
                    <BDP:BasicDatePicker ID="bdp_birthday" runat="server" DateFormat="yyyy-MM-dd" ReadOnly="True"></BDP:BasicDatePicker>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="bdp_birthday"
                        ErrorMessage="Please choose birthday." ValidationGroup="vl">*</asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td align="right">Avatar</td>
                <td><asp:FileUpload ID="file_upload" runat="server" /></td>
            </tr>
            <tr>
                <td></td>
                <td>
                    <asp:Button ID="btn_save" ValidationGroup="vl" class="btnWhite" runat="server" Text="Register" onclick="btn_save_Click" />
                    <asp:Button ID="btn_reset" class="btnWhite" runat="server" Text="Reset" onclick="btn_reset_Click" />
                    <div style="font-size: 15px; color: #F00; padding-top: 10px">
                        <b><asp:Label ID="lbl_msg" runat="server" Text=""></asp:Label></b>
                    </div>
                </td>
            </tr>
        </table>        
    </div>
    
    <div id="layout_success" runat="server" visible="false">
        <div align="center">
            <div style="color:#F00;font-size:15px;padding-bottom:5px"><b>Register successfully</b></div>
            <div>Click here [ <a href="login.aspx">Log In</a> ]</div>
        </div>        
    </div>
</fieldset>
</asp:Content>